package com.zw.yzk.kabu.skin;

import android.content.Context;
import skin.support.SkinCompatManager;

/**
 * Created by skydar on 2017/4/15.
 */

public class MySkinManager {
    private static volatile MySkinManager sInstance;

    public static MySkinManager init(Context context) {
        if (sInstance == null) {
            synchronized (MySkinManager.class) {
                if (sInstance == null) {
                    sInstance = new MySkinManager(context);
                }
            }
        }
        return sInstance;
    }

    public static MySkinManager getInstance() {
        return sInstance;
    }

    private MySkinManager(Context context) {
        // 给自定义皮肤控件添加
        SkinCompatManager.init(context).addInflater(new SkinCheckBoxInflater());
    }
}
